package com.itheima.demo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@NoArgsConstructor
@AllArgsConstructor
/**
 * @author jiangxun
 * @date 11-20-2024
 */
public class ElectricAppliance implements Switch{
    private String name;
    private boolean status;
    @Override
    public void press() {
        status =!status;
    }
}

